<?php

use Illuminate\Routing\Router;

Admin::registerHelpersRoutes();

Route::group([
    'prefix'        => config('admin.prefix'),
    'namespace'     => Admin::controllerNamespace(),
    'middleware'    => ['web', 'admin'],
], function (Router $router) {

    $router->get('/', 'HomeController@index');
    $router->post('editor_upload', 'UploadController@postUploadPicture');

    $router->resources([
        'baoming' => BaomingController::class,
        'pro_category' => ProCategoryController::class,
        'pro_products' => ProProductsController::class,
        'web_content' => WebContentController::class,
        'music' => MusicController::class,
        'banners' => BannersController::class,
    ]);
});
